<template>
    <div id="app">
        <AppMain />
    </div>
</template>
<script>
import AppMain from './layouts/appMain.vue'

export default {
    components: {
        AppMain,
    },
    data() {
        return {}
    },
    created() {
        if (!this.$utils.isIos()) {
            this.keyboardListener()
        }
    },
    methods: {
        // 监听弹起键盘事件
        keyboardListener() {
            var win_h = document.documentElement.clientHeight //关键代码
            window.addEventListener('resize', () => {
                if (document.documentElement.clientHeight < win_h) {
                    this.$store.commit('SET_STATE', { isFous: true })
                } else {
                    this.$store.commit('SET_STATE', { isFous: false })
                }
            })
        },
    },
}
</script>
<style lang="scss">
@import '~h5/assets/scss/theme.scss';
@import '~h5/assets/scss/custom.scss';
@import '~h5/assets/scss/global.scss';
//富文本编器样式
@import '~@/styles/markdown.scss';
@import '~@/styles/icon.scss';
@import '~h5/styles/clipper.scss';
</style>
